<!DOCTYPE html>
<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 
<meta charset="utf-8">  

<meta name="viewport" content="target-densitydpi=320,width=320,user-scalable=no, minimal-ui">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black"> 
<title>嫦娥爱色兔</title>
<script src="{$_W['siteroot']}addons/voldemort_moon/template/mobile/images/easeljs-0.7.1.min.js"></script>
<script src="{$_W['siteroot']}addons/voldemort_moon/template/mobile/images/tweenjs-0.5.1.min.js"></script>
<script src="{$_W['siteroot']}addons/voldemort_moon/template/mobile/images/movieclip-0.7.1.min.js"></script>
<script src="{$_W['siteroot']}addons/voldemort_moon/template/mobile/images/preloadjs-0.4.1.min.js"></script>
<script src="{$_W['siteroot']}addons/voldemort_moon/template/mobile/images/moon.js"></script>
<script src="{$_W['siteroot']}addons/voldemort_moon/template/mobile/images/jquery.js"></script>
<style>
	*{-webkit-touch-callout:none;
	-webkit-touch-callout: none; /* prevent callout to copy image, etc when tap to hold */
-webkit-text-size-adjust: none; /* prevent webkit from resizing text to fit */
-webkit-tap-highlight-color: rgba(0,0,0,0); /* make transparent link selection, adjust last value opacity 0 to 1.0 */
-webkit-user-select: none; /* prevent copy paste, to allow, change 'none' to 'text' */
	}
	#sharediv{width:100%; height:100%; background:#000; opacity:0.9; position:fixed; left:0px; top:0px; z-index:9999; text-align:right; display:none;}
	#sharediv img{width:412px;}
</style>
<script>


//*配置文件********************************************
//关卡
var guanka= 0;
//百分比var perNum=0;
 

//*****************************************************
var canvas, stage, exportRoot;

function init2() {
	canvas = document.getElementById("canvas");
	exportRoot = new lib.moon();

	stage = new createjs.Stage(canvas);
	stage.addChild(exportRoot);
	stage.update();
	stage.enableMouseOver();

	createjs.Ticker.setFPS(lib.properties.fps);
	createjs.Ticker.addEventListener("tick", stage);
	
}
function init() {
	canvas = document.getElementById("canvas");
	images = images||{};

	var loader = new createjs.LoadQueue(false);
	loader.addEventListener("fileload", handleFileLoad);
	loader.addEventListener("complete", handleComplete);
	loader.loadManifest(lib.properties.manifest);
}

function handleFileLoad(evt) {
	if (evt.item.type == "image") { images[evt.item.id] = evt.result; }
}

function handleComplete() {
	exportRoot = new lib.moon();

	stage = new createjs.Stage(canvas);
	stage.addChild(exportRoot);
	stage.update();
	stage.enableMouseOver();
	
	stage.enableMouseOver();
	
	stage.enableMouseOver(10);
	stage.mouseMoveOutside = true; // keep tracking the mouse even when it leaves the canvas
	createjs.Touch.enable(stage);

	createjs.Ticker.setFPS(lib.properties.fps);
	createjs.Ticker.addEventListener("tick", stage);
	//jQuery("#loading").hide();
}
</script>
</head>

<body onload="init();" style="background-color:#202330; margin:0px; padding:0px;" youdao="bind">
	<canvas id="canvas" width="720" height="1100" style="background-color: rgb(32, 35, 48);"></canvas>
<div id="moregame" style="display: block; position: fixed; bottom: 10px; left: 0px; font-size: 40px; width: 100%; text-align: center;"></div>      

<script language="javascript">
    var mebtnopenurl = window.location.href;
		window.shareData = {
		        "imgUrl": "{$_W['siteroot']}addons/voldemort_moon/template/mobile/images/preview.jpg",
            "timeLineLink": window.location.href,
		        "tTitle": "嫦娥爱色兔",
		        "tContent": "快来帮助嫦娥收集玉兔吧！"
		};
				
		function goHome(){
			window.location=mebtnopenurl;
		}
		
		function dp_share(){
			document.getElementById("share").style.display="";
			
		}
		function dp_Ranking(){
			window.location=mebtnopenurl;
		}

		function showAd(){
		}
		function hideAd(){
		}
		document.addEventListener('WeixinJSBridgeReady', function onBridgeReady() {
		    
		    WeixinJSBridge.on('menu:share:appmessage', function(argv) {
		        WeixinJSBridge.invoke('sendAppMessage', {
		            "img_url": window.shareData.imgUrl,
		            "link": window.shareData.timeLineLink,
		            "desc": window.shareData.tContent,
		            "title": window.shareData.tTitle
		        }, onShareComplete);
		    });

		    WeixinJSBridge.on('menu:share:timeline', function(argv) {
		        WeixinJSBridge.invoke('shareTimeline', {
		            "img_url": window.shareData.imgUrl,
		            "img_width": "640",
		            "img_height": "640",
		            "link": window.shareData.timeLineLink,
		            "desc": window.shareData.tContent,
		            "title": window.shareData.tTitle
		        }, onShareComplete);
		    });
		}, false);
		</script>
		<div id="share" style="display: none">
			<img width="100%" src="{$_W['siteroot']}addons/voldemort_moon/template/mobile/images/preview.jpg" style="position: fixed; z-index: 9999; top: 0; left: 0; display: " ontouchstart="document.getElementById(&#39;share&#39;).style.display=&#39;none&#39;;">
		</div>
			<script type="text/javascript">
            var myData = { gameid: "ce" };
			 var domain = ["{$_W['siteroot']}", "{$_W['siteroot']}", "{$_W['siteroot']}"][parseInt(Math.random() * 3)];
                window.shareData.timeLineLink = "{$_W['siteroot']}" +"/"+ myData.gameid +"/"+"index.html?gameid=" + myData.gameid + (localStorage.myuid ? "&uid=" + localStorage.myuid : "");
			function dp_submitScore(score,percent){
					if(score>0){
						myData.score = parseInt(score);
						myData.scoreName ="收集了"+score+"只兔子";		
						document.title = window.shareData.tTitle = "我为嫦娥姐姐集了"+score+"只兔子，击败了"+percent+"%的人，你也来帮下嫦娥吧！";
					}
			}
			function onShareComplete(res) {
    //             if (localStorage.myuid && myData.score != undefined) {
    //                 setTimeout(function(){
    //                     if (confirm("要将成绩提交到游戏排行榜吗？")) {
    //                         window.location = "http://wx.9g.com/rank/submit2.jsp?gameid=" + myData.gameid + "&uid=" + localStorage.myuid + "&score=" + myData.score + "&scorename=" + encodeURIComponent(myData.scoreName);
    //                     }
    //                     else {
    //                         document.location.href = mebtnopenurl;
    //                     }
    //                 }, 500);
    //             }
				// else {
		  //       	document.location.href = mebtnopenurl;
				// }
	        }
			</script>
			
</body></html>